Segment logic
نویسنده
چکیده
O’Hearn, Reynolds and Yang introduced local Hoare reasoning about mutable data structures using separation logic. They reason about the local parts of the memory accessed by programs, and thus construct their smallest complete specifications. Gardner et al. generalised their work, using context logic to reason about structured data at the same level of abstraction as the data itself. In particular, we developed a formal specification of the Document Object Model (DOM), a W3C XML update library. Whilst we kept to the spirit of local reasoning, we were not able to retain small specifications for all of the commands of DOM: for example, our specification of the appendChild command was not small. We show how to obtain such small specifications by developing a more fine-grained context structure, allowing us to work with arbitrary segments of a data structure. We introduce segment logic, a logic for reasoning about such segmented data structures, staring at first with a simple tree structure, but then showing how to generalise our approach to arbitrary structured data. Using our generalised segment logic we construct a reasoning framework for abstract program modules, showing how to reason about such modules at the client level. In particular we look at modules for trees, lists, heaps and the more complex data model of DOM. An important part of any abstraction technique is an understanding of how to link the abstraction back to concrete implementations. Building on our previous abstraction and refinement work for local reasoning, we show how to soundly implement the segment models used in our abstract reasoning. In particular we show how to implement our fine-grained list and tree modules so that their abstract specifications are satisfied by the concrete implementations. We also show how our reasoning from the abstract level can be translated to reasoning at the concrete level. Finally, we turn our attention to concurrency and show how having genuine small axioms for our commands allows for a simple treatment of abstract level concurrency constructs.
منابع مشابه
Strategy-aligned fuzzy approach for market segment evaluation and selection: a modular decision support system by dynamic network process (DNP)
In competitive markets, market segmentation is a critical point of business, and it can be used as a generic strategy. In each segment, strategies lead companies to their targets; thus, segment selection and the application of the appropriate strategies over time are very important to achieve successful business. This paper aims to model a strategy-aligned fuzzy approach to market segment ev...
متن کاملHelix Segment Assignment in Proteins Using Fuzzy Logic
The automatic assignment of protein secondary structure from three dimensional coordinates is an essential step in the characterization of protein structure. <span style="font...
متن کاملCertainty Measure of Pairwise Line Segment Perceptual Relations Using Fuzzy Logic
Perceptual grouping is an important part of many computer vision systems. When inferring a new grouping from the primitive features there is always an uncertainty degree on this detection, that might be useful in further reasonings. In this paper, we present a fuzzy logic based system for the computation of the certainties assigned to pairwise line segment relations and introduce its applicatio...
متن کاملGenerating segment durations in a text-zo-speech system: a hybrid rule-based/neural network approach
A combination of a neural network with rule firing information from a rule-based system is used to generate segment durations for a text-to-speech system. The system shows a slight improvement in performance over a neural network system without the rule firing information. Synthesized speech using segment durations was accepted by listeners as having about the same quality as speech generated u...
متن کاملVerification of Railway Interlockings in Scade
We present two modelling approaches for the application of model checking to verify railway interlockings. The first translates so-called Ladder Logic into Scade language, the second models a segment of railway from scratch. The verification tool used is Scade.
متن کامل